#ifndef HPLC_QINFINE_PUMPPARSESYSTEMPACKET_H
#define HPLC_QINFINE_PUMPPARSESYSTEMPACKET_H

#include <QObject>
#include "modulehplcpumpdefine.h"
#include "common/hplcqinfineparsecommonsystempacket.h"

namespace hplc
{
namespace qinfine
{

class HplcQinfinePumpProtocolData;
class HplcQinfinePumpParseSystemPacket : public QObject
{
    Q_OBJECT

public:
    HplcQinfinePumpParseSystemPacket(HplcQinfinePumpProtocolData &data, hplc::PumpParam &param, QObject *parent = nullptr);

    void parseSet(quint8 pfc, char *data);
    void parseGet(quint8 pfc, char *data);

signals:
    void parseCompleted(int id, const QVariant &data);

    void setWorkMode(quint8 mode);
    void setFlowCalibData(const QList<hplc::PumpRateCalibData> &list);
    void setFlowCalibLoadFlow(float flow);
    void setFlowCalibLoadRealFlow(float flow);
    void setFlowCalibLoadPressure(float pressure);
    void setPressureCalibData(QList<hplc::PumpPressureCalibData> list);
    void setPulseCompenCalibData(QList<hplc::PumpPulseCompenCalibData> list);
    void setPulseCompenGearPos(qint32 pos);
    void setMotorIRun(quint8 current);
    void setMotorCurrentCalibData(QList<hplc::PumpStepMotorCurrentCalibData> list);

protected:
    HplcQinfinePumpProtocolData 		*m_d = nullptr;
    hplc::PumpParam			*m_param = nullptr;
};

} // qinfine
} // hplc

#endif // HPLC_QINFINE_PUMPPARSESYSTEMPACKET_H
